<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<c:set var="ctx" value="${pageContext.request.contextPath }"/>
<%@taglib prefix="shiro" uri="http://shiro.apache.org/tags" %>
<!-- BEGIN HEADER -->
	<div class="header navbar navbar-inverse navbar-fixed-top">
		<!-- BEGIN TOP NAVIGATION BAR -->
		<div class="header-inner">
			<!-- BEGIN LOGO -->
			<a class="navbar-brand" style="margin-left:-5px; width:30px;" href="${ctx }/tixing/shouye.do">
				<img src="${ctx }/logo/logo.png" alt="logo" style="display:block;height:50px;" />
			</a>
			<a class="navbar-brand" style="margin-left:60px;margin-top:12px;width:300px;" href="${ctx }/tixing/shouye.do" >
				<span class="header-title">固定资产管理系统</span>
			</a>
			<!-- END LOGO -->
			
			<!-- BEGIN TOP NAVIGATION MENU -->
			<ul class="nav navbar-nav pull-right">				
				<!-- BEGIN USER LOGIN DROPDOWN -->
				<li class="dropdown user">
					<a href="#" class="dropdown-toggle" data-toggle="dropdown" data-hover="dropdown" data-close-others="true">
					
					<span class="username" id="name"></span>
					<i class="fa fa-angle-down"></i>
					</a>
					<ul class="dropdown-menu">
						<li><a href="${ctx }/system/changePasssword.do"><i class="fa fa-key"></i>修改密码</a></li>
						<li><a href="${ctx }/system/logout.do"><i class="fa fa-key"></i>退出登录</a></li>
					</ul>
				</li>
				<!-- END USER LOGIN DROPDOWN -->
			</ul>
			<!-- END TOP NAVIGATION MENU -->
		</div>
		<!-- END TOP NAVIGATION BAR -->
	</div>
	<!-- END HEADER -->
<script src="${ctx}/assets/plugins/jquery-1.10.2.min.js" type="text/javascript"></script>
<script>
	jQuery(document).ready(function() {       
	   // initiate layout and plugins	  
	   $.ajax({
		   url:"${ctx}/system/getName.do?userName="+"<shiro:principal/>",
		   dataType:"json",
			success:function(data){
				$('#name').html(data.result);
			}
	   });
	});
</script>